import { http } from '@/utils/http'

// 标签数量
export const getCostCountApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/count',
    data: params,
  })
}

// 运营成本审批人列表
export const getApprovalSetings = (params) => {
  return http({
    method: 'POST',
    url: '/V5/costCheckFlow/list',
    data: params,
  })
}
// 获取员工银行收款账户
export const staffDetail = (params) => {
  return http({
    method: 'POST',
    url: '/V5/staff/detail',
    data: params,
  })
}
// 获取员工列表
export const getStaffList = (params) => {
  return http({
    method: 'POST',
    url: '/V5/staff/pageList',
    data: params,
  })
}
// 运营成本详情
export const getCostDetailApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/detail',
    data: params,
  })
}
//  运营成本重新申请，修改详情
export const getNewCostDetailApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/detailForRenew',
    data: params,
  })
}
// 运营成本新增&编辑
export const editCostApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/edit',
    data: params,
  })
}

// 审批
export const checkCostApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/check',
    data: params,
  })
}

// 撤销
export const revokeCostApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/revoke',
    data: params,
  })
}

// 作废
export const nullifyCostApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/nullify',
    data: params,
  })
}
// 付款
export const payCostApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/pay',
    data: params,
  })
}

// 导出
export const exportExcel = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/exportExcel',
    data: params,
  })
}

// 开户行所在省市查询
export const findAreaSelect = (params) => {
  return http({
    method: 'POST',
    url: '/V5/area/findAreaSelect',
    data: params,
  })
}
// 获取登录用户信息
export const getLoginUserInfo = (params) => {
  return http({
    method: 'POST',
    url: '/V5/staff/findLoginStaffInfo',
    data: params,
  })
}

// 新增员工银行账户信息
export const addStaffBankInfo = (params) => {
  return http({
    method: 'POST',
    url: '/V5/staff/saveBank',
    data: params,
  })
}

// 新增同行银行账户信息
export const addPeerBankInfo = (params) => {
  return http({
    method: 'POST',
    url: '/V5/sameIndustryInfo/saveBank',
    data: params,
  })
}

// 新增供应商银行账户信息
export const addSupplierBankInfo = (params) => {
  return http({
    method: 'POST',
    url: '/supplier/saveBank',
    data: params,
  })
}

// 同行收款账号列表
export const getPeerList = (params) => {
  return http({
    method: 'POST',
    url: '/V5/sameIndustryInfo/detail',
    data: params,
  })
}

// 供应商收款账号列表
export const getSupplierList = (params) => {
  return http({
    method: 'POST',
    url: '/supplier/detail',
    data: params,
  })
}
// tab审批状态数量
export const getStatusCount = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/statusCount',
    data: params,
  })
}

// 查询短租订单服务过的车辆列表
export const getShortCarRecord = (params) => {
  return http({
    method: 'POST',
    url: '/V5/sOrder/getCarUseRecordByOrderId',
    data: params,
  })
}

// 查询长租订单服务过的车辆列表
export const getLongCarRecord = (params) => {
  return http({
    method: 'POST',
    url: '/V5/czsOrderInfo/getCarUseRecordByOrderId',
    data: params,
  })
}

// 查询审批流程历史
export const getCheckHistoryApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/checkHistory',
    data: params,
  })
}

// 财务打款凭证提交
export const updatePayFileApi = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/updatePayFile',
    data: params,
  })
}

// 列表统计
export const getListCount = (params) => {
  return http({
    method: 'POST',
    url: '/V5/cost/listCount',
    data: params,
  })
}


